package org.example.service;

import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.example.entity.Business;
import org.example.mapper.IBusinessMapper;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class BusinessService extends ServiceImpl<IBusinessMapper, Business> {

    // 根据 orderTypeId 查询商家列表
    public List<Business> listBusinessByOrderTypeId(Integer orderTypeId) {
        return baseMapper.listBusinessByOrderTypeId(orderTypeId);
    }

    // 根据 businessId 查询商家信息
    public Business getBusinessById(Integer businessId) {
        return baseMapper.getBusinessById(businessId);
    }
} 